package com.qax.task.cron;

/**
 * Task abstract for in project ,swapper for {@link Runnable}
 * @see java.util.concurrent.Callable
 *
 * @author leiliang
 */
public class Task {

    private final Runnable runnable;

    /**
     * Create a new {@code Task}.
     * @param runnable the underlying task to execute
     */
    public Task(Runnable runnable) {
        this.runnable = runnable;
    }


    /**
     * Return the underlying task.
     */
    public Runnable getRunnable() {
        return this.runnable;
    }


    @Override
    public String toString() {
        return this.runnable.toString();
    }


}
